"""
21 - Dars
"""
WORDS = ['мадам', 'топот', 'test', 'madam', 'word']
PALINDROMES = []

for WORD in WORDS:
    if WORD == WORD[::-1]:
        PALINDROMES.append(WORD)

PALINDROMES = [WORD for WORD in WORDS if WORD == WORD[::-1]]

print(PALINDROMES)

MY_STR = ['Око за око', 'А роза упала на лапу Азора', 'Около Миши молоко']
PALINDROMES = []
for WORD in MY_STR:
    WORD_R = WORD.replace(' ', '').lower()
    if WORD_R == WORD_R[::-1]:
        PALINDROMES.append(WORD)

print(PALINDROMES)

L = list(range(1, 10))
L2 = list('hello')

print(L, L2, type(L))

S = '-'.join(map(str, L))
S2 = ','.join(L2)

print(S, type(S))
print(S2, type(S2))
